const bcrypt = require('bcryptjs')
const { sequelize } = require('../../../core/db');
const { Sequelize,Model } = require('sequelize');
const { NotFound,AuthFailed } = require('../../../core/httpException');

// 商品规格表
class GoodSpec extends Model{

}

GoodSpec.init({
    id:{
        type:Sequelize.INTEGER,
        primaryKey:true,
        autoIncrement:true
    },
    product_id:{  //商品ID
        type:Sequelize.INTEGER
    },
    product_specs:Sequelize.TEXT,  // 规格中文
    stock:Sequelize.INTEGER,  // 规格库存
    price:Sequelize.INTEGER // 规格价格
   
},{
    sequelize,
    tableName:'good_spec'
})

module.exports = { GoodSpec }